CREATE TABLE [dbo].[TDDEVA_CAJP]
(
[CO_EMPR] [dbo].[TD_VC_002] NOT NULL,
[CO_CAJA] [varchar] (8) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[AA_CAJA] [varchar] (4) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[MM_CAJA] [varchar] (2) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[TI_MOVI] [varchar] (1) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[NU_COMP_CAJA] [varchar] (8) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[NU_SECU] [int] NOT NULL CONSTRAINT [DF__TDDEVA_CA__NU_SE__68336F3E] DEFAULT ((0)),
[CO_TIPO_DOCU] [varchar] (3) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[NU_DOCU_PROV] [varchar] (20) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[IM_DEVO] [numeric] (16, 4) NULL CONSTRAINT [DF__TDDEVA_CA__IM_DE__69279377] DEFAULT ((0)),
[IM_DEVO_CONV] [numeric] (16, 4) NULL CONSTRAINT [DF__TDDEVA_CA__IM_DE__6A1BB7B0] DEFAULT ((0)),
[CO_USUA_CREA] [varchar] (8) COLLATE SQL_Latin1_General_CP1_CI_AS NULL CONSTRAINT [DF__TDDEVA_CA__CO_US__6B0FDBE9] DEFAULT (suser_sname()),
[FE_USUA_CREA] [datetime] NULL CONSTRAINT [DF__TDDEVA_CA__FE_US__6C040022] DEFAULT (getdate()),
[CO_USUA_MODI] [varchar] (8) COLLATE SQL_Latin1_General_CP1_CI_AS NULL CONSTRAINT [DF__TDDEVA_CA__CO_US__6CF8245B] DEFAULT (suser_sname()),
[FE_USUA_MODI] [datetime] NULL CONSTRAINT [DF__TDDEVA_CA__FE_US__6DEC4894] DEFAULT (getdate())
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TDDEVA_CAJP] ADD CONSTRAINT [PK__TDDEVA_C__728CABD33DC8FF7D] PRIMARY KEY CLUSTERED  ([CO_EMPR], [CO_CAJA], [AA_CAJA], [MM_CAJA], [TI_MOVI], [NU_COMP_CAJA], [NU_SECU]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[TDDEVA_CAJP] ADD CONSTRAINT [FK__TDDEVA_CA__CO_EM__418481C8] FOREIGN KEY ([CO_EMPR]) REFERENCES [dbo].[TMPARA_TESO] ([CO_EMPR])
GO
